home *** CD-ROM | disk | FTP | other *** search
/ Stone Design / Stone Design.iso / Stone_Friends / Wave / WavesWorld / Source / Libraries / tcl7.4b3 / doc / set.n < prev    next >
Encoding:
Text File  |  1994-12-17  |  1.3 KB  |  39 lines

  1. '\"
  2. '\" Copyright (c) 1993 The Regents of the University of California.
  3. '\" Copyright (c) 1994 Sun Microsystems, Inc.
  4. '\"
  5. '\" See the file "license.terms" for information on usage and redistribution
  6. '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  7. '\" 
  8. '\" @(#) set.n 1.2 94/12/17 16:18:47
  9. '\" 
  10. .so man.macros
  11. .HS set tcl
  12. .BS
  13. '\" Note:  do not modify the .SH NAME line immediately below!
  14. .SH NAME
  15. set \- Read and write variables
  16. .SH SYNOPSIS
  17. \fBset \fIvarName \fR?\fIvalue\fR?
  18. .BE
  19.  
  20. .SH DESCRIPTION
  21. .PP
  22. Returns the value of variable \fIvarName\fR.
  23. If \fIvalue\fR is specified, then set
  24. the value of \fIvarName\fR to \fIvalue\fR, creating a new variable
  25. if one doesn't already exist, and return its value.
  26. If \fIvarName\fR contains an open parenthesis and ends with a
  27. close parenthesis, then it refers to an array element:  the characters
  28. before the first open parenthesis are the name of the array, and the characters
  29. between the parentheses are the index within the array.
  30. Otherwise \fIvarName\fR refers to a scalar variable.
  31. If no procedure is active, then \fIvarName\fR refers to a global
  32. variable.
  33. If a procedure is active, then \fIvarName\fR refers to a parameter
  34. or local variable of the procedure unless the \fIglobal\fR command
  35. has been invoked to declare \fIvarName\fR to be global.
  36.  
  37. .SH KEYWORDS
  38. read, write, variable
  39.